<template>
    <div class="box">
        <biaoti title="详情"></biaoti>
        <van-tabs v-model:active="active">
            <van-tab title="商品">
             <lunbo :list="delist.pics"></lunbo>   
             <p>{{ delist.goods_name }}</p>
             <p style="color: red;">${{ delist.goods_price }}</p>
            </van-tab>
            <van-tab title="详情">
                <div v-html="delist.goods_introduce"></div>
            </van-tab>
            <van-tab title="评价">内容 3</van-tab>
        
        </van-tabs>
    </div>
</template>

<script setup>
import { ref } from 'vue'
import biaoti from '@/components/biaoti.vue'
import lunbo from '@/components/lunbo.vue'
import { detailApi } from '@/api/api'
import { useRoute, useRouter } from 'vue-router'
const router = useRouter()
const route = useRoute()
let goods_id = ref(route.query.goods_id)
let delist = ref("")
const delFun = () => {
    detailApi(goods_id.value).then(res => {
        delist.value = res.data.message
    })
}
delFun()
</script>

<style lang="scss" scoped>
.box{
    overflow: auto;
}
</style>